import  openpyxl
from openpyxl.styles import Font
wb = openpyxl.Workbook()
ws = wb.active
ws.title ='Font'

#default 11pt Calibri
italic24Font = Font(size=24,italic=True)
ws['B3'].font = italic24Font
ws['B3'] = '24pt Italic'

boldRedFont = Font(name="Times New Roman",bold=True,color='FF0000')
ws['A1'].font = boldRedFont
ws['A1'] = 'Bold Red Times New Roman'

ws =wb.create_sheet('Formula')
ws['A1'] = 200
ws['A2'] = 300
ws['A3'] = '=SUM(A1:A2)'

ws = wb.create_sheet('dimensions')
ws['A1'] = 'Tall row'
ws.row_dimensions[1].height = 70
ws['B2'] = 'Wide colume'
ws.column_dimensions['B'].width = 20

ws = wb.create_sheet('merged')
ws.merge_cells('A1:D3')
ws['A1'] = "Twelve cells merged togther"
ws.merge_cells("D5:E5")
ws['D5'] = 'TWo merged cells'



wb.save('style.xlsx')